home *** CD-ROM | disk | FTP | other *** search
/ IRIX 6.5 Applications 2002 November / SGI IRIX 6.5 Applications 2002 November.iso / dist / sgi_apache.idb / var / sgi_apache / server / include / hsregex.h.z / hsregex.h
Encoding:
C/C++ Source or Header  |  2002-06-27  |  2.2 KB  |  91 lines

  1. /* DON'T EVEN THINK ABOUT EDITING THIS, go see regex/Makefile,
  2.  * search for mkh */
  3. #ifndef _REGEX_H_
  4. #define    _REGEX_H_    /* never again */
  5. /* ========= begin header generated by ./mkh ========= */
  6. #ifdef __cplusplus
  7. extern "C" {
  8. #endif
  9.  
  10. /* === regex2.h === */
  11. #ifndef API_EXPORT
  12. #ifdef WIN32
  13. #define API_EXPORT(type)    __declspec(dllexport) type __stdcall
  14. #else
  15. #define API_EXPORT(type)    type
  16. #endif
  17. #endif
  18.  
  19. #undef ap_private_extern
  20. #if defined(MAC_OS) || defined(MAC_OS_X_SERVER) || (defined(DARWIN) && defined(__DYNAMIC__))
  21. #define ap_private_extern __private_extern__
  22. #else
  23. #define ap_private_extern
  24. #endif
  25.  
  26. typedef off_t regoff_t;
  27. typedef struct {
  28.     int re_magic;
  29.     size_t re_nsub;        /* number of parenthesized subexpressions */
  30.     const char *re_endp;    /* end pointer for REG_PEND */
  31.     struct re_guts *re_g;    /* none of your business :-) */
  32. } regex_t;
  33. typedef struct {
  34.     regoff_t rm_so;        /* start of match */
  35.     regoff_t rm_eo;        /* end of match */
  36. } regmatch_t;
  37.  
  38.  
  39. /* === regcomp.c === */
  40. API_EXPORT(int) regcomp(regex_t *, const char *, int);
  41. #define    REG_BASIC    0000
  42. #define    REG_EXTENDED    0001
  43. #define    REG_ICASE    0002
  44. #define    REG_NOSUB    0004
  45. #define    REG_NEWLINE    0010
  46. #define    REG_NOSPEC    0020
  47. #define    REG_PEND    0040
  48. #define    REG_DUMP    0200
  49.  
  50.  
  51. /* === regerror.c === */
  52. #define    REG_NOMATCH     1
  53. #define    REG_BADPAT     2
  54. #define    REG_ECOLLATE     3
  55. #define    REG_ECTYPE     4
  56. #define    REG_EESCAPE     5
  57. #define    REG_ESUBREG     6
  58. #define    REG_EBRACK     7
  59. #define    REG_EPAREN     8
  60. #define    REG_EBRACE     9
  61. #define    REG_BADBR    10
  62. #define    REG_ERANGE    11
  63. #define    REG_ESPACE    12
  64. #define    REG_BADRPT    13
  65. #define    REG_EMPTY    14
  66. #define    REG_ASSERT    15
  67. #define    REG_INVARG    16
  68. #define    REG_ATOI    255    /* convert name to number (!) */
  69. #define    REG_ITOA    0400    /* convert number to name (!) */
  70. API_EXPORT(size_t) regerror(int, const regex_t *, char *, size_t);
  71.  
  72.  
  73. /* === regexec.c === */
  74. API_EXPORT(int) regexec(const regex_t *, const char *, size_t, regmatch_t [], int);
  75. #define    REG_NOTBOL    00001
  76. #define    REG_NOTEOL    00002
  77. #define    REG_STARTEND    00004
  78. #define    REG_TRACE    00400    /* tracing of execution */
  79. #define    REG_LARGE    01000    /* force large representation */
  80. #define    REG_BACKR    02000    /* force use of backref code */
  81.  
  82.  
  83. /* === regfree.c === */
  84. API_EXPORT(void) regfree(regex_t *);
  85.  
  86. #ifdef __cplusplus
  87. }
  88. #endif
  89. /* ========= end header generated by ./mkh ========= */
  90. #endif
  91.